Microsoft DirectX 8.1 (C++)

AMTimelineObj.GetUserData Method

The AMTimelineObj.GetUserData method retrieves application-defined persistent data.

Syntax

object.GetUserData(
    pData As Byte,
    pSize As Long
)

Parameters

pData

Reference to an array of bytes that contains the data.

pSize

Size of the array, in bytes. When the method returns, the value is set to the required size. See Remarks.

Error Codes

If the method fails, an error is raised.

Remarks

This method sets the value of pSize equal to the array size needed for the user data. Use the ReDim statement to resize the array and call the method again. Pass the pData parameter by reference, using the first element of the array as the parameter value.

Code Example

Dim UserData(0) As Byte
Dim Size As Long

' Find the required size.
ReDim UserData(1)
objTimelineObject.GetUserData UserData(0), Size

' Resize the array and get all the data.
If Size <> 0 Then
    ReDim UserData(Size)
    objTimelineObject.GetUserData UserData(0), Size
End If

See Also